﻿<Window x:Class="QLVT2.HoaDonWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        Title="Hoa Don" Height="350" Width="525" Loaded="Window_Loaded">
    <Grid>
        <Grid.RowDefinitions>
            <RowDefinition Height="auto"/>
            <RowDefinition Height="*"/>
            <RowDefinition Height="auto"/>  
        </Grid.RowDefinitions>
        <ToolBarTray  Grid.Row="0"  >
            <ToolBar Band="1" BandIndex="1">
                <Button  Name="mnNew" ToolTip="New">
                    <StackPanel Orientation="Horizontal">
                        <Image HorizontalAlignment="Right" Source="Images\NewDocumentHS.png "/>
                        <TextBlock VerticalAlignment="Center">Thêm Mới</TextBlock>
                    </StackPanel>
                </Button>
                <Button  Name="sua" ToolTip="Sua">
                    <StackPanel Orientation="Horizontal">
                        <Image HorizontalAlignment="Right" Source="Images\EditTableHS.png "/>
                        <TextBlock VerticalAlignment="Center">Sửa</TextBlock>
                    </StackPanel>
                </Button>
                <Button  Name="xoa" ToolTip="Xoa" Click="xoa_Click">
                    <StackPanel Orientation="Horizontal">
                        <Image HorizontalAlignment="Right" Source="Images\DeleteHS.png"/>
                        <TextBlock VerticalAlignment="Center">Xóa</TextBlock>
                    </StackPanel>
                </Button>
                <Button  Name="tkiem" ToolTip="Timkiem">
                    <StackPanel Orientation="Horizontal">
                        <Image HorizontalAlignment="Right" Source="Images\Find_VS.png "/>
                        <TextBlock VerticalAlignment="Center">Tìm Kiếm</TextBlock>
                    </StackPanel>
                </Button>
                <Button ToolTip="Print">
                    <StackPanel Orientation="Horizontal">
                        <Image Width="16" Height="16" Source="Images\PrintArea.png "/>
                        <TextBlock VerticalAlignment="Center">In</TextBlock>
                    </StackPanel>
                </Button>
                <Separator/>
                <Button ToolTip="Close" Name="btClose" Click="btClose_Click" >
                    <StackPanel Orientation="Horizontal">
                        <Image Width="16" Height="16" Source="Images\StopHS.png " />
                        <TextBlock VerticalAlignment="Center">Thoát</TextBlock>
                    </StackPanel>
                </Button>
            </ToolBar>
        </ToolBarTray>
        <DataGrid Name="datagrid" Grid.Row="1" AutoGenerateColumns="False">
            <DataGrid.Columns>
                <DataGridTextColumn Header="Số hóa đơn" Width="75" Binding="{Binding sohd}"></DataGridTextColumn>
                <DataGridTextColumn Header="Tên Hàng" Width="100" Binding="{Binding tenhang}"></DataGridTextColumn>
                <DataGridTextColumn Header="Số Lượng" Width="75" Binding="{Binding soluong}"></DataGridTextColumn>
                <DataGridTextColumn Header="Đơn Giá " Width="100" Binding="{Binding dongia}"></DataGridTextColumn>
                <DataGridTextColumn Header="Trị Giá" Width="100" Binding="{Binding trigia}"></DataGridTextColumn>
                <DataGridTextColumn Header="Khuyến Mãi" Width="75" Binding="{Binding khuyenmai}"></DataGridTextColumn>
                <DataGridTextColumn Header="Diễn Giải" Width="*" Binding="{Binding diengiai}"></DataGridTextColumn>
            </DataGrid.Columns>           
        </DataGrid>
        <StatusBar Grid.Row="2">
            <StatusBarItem Content="Tổng số hóa đơn:"/>
        </StatusBar>
    </Grid>
</Window>
